From: Ian Campbell Date: Mon, 30 Mar 2015 11:12:25 +0000 (+0100) Subject: xen: arm: Use ARMv8 names for CNTHCTL_EL2 bits X-Git-Tag: archive/raspbian/4.8.0-1+rpi1~1^2~3499 X-Git-Url: https://dgit.raspbian.org/%22http:/www.example.com/cgi/%22https:/%22bookmarks://%22Dat/%22http:/www.example.com/cgi/%22https:/%22bookmarks:/%22Dat?a=commitdiff_plain;h=bec51f0544189b2953384b547d70eb39b12704bb;p=xen.git xen: arm: Use ARMv8 names for CNTHCTL_EL2 bits Rather than using the v8 register names and the v7 bit names, which makes things needlessly difficult when reading. Signed-off-by: Ian Campbell Reviewed-by: Julien Grall --- diff --git a/xen/arch/arm/time.c b/xen/arch/arm/time.c index 352e25e786..ce6d3fd5dc 100644 --- a/xen/arch/arm/time.c +++ b/xen/arch/arm/time.c @@ -230,7 +230,7 @@ void __cpuinit init_timer_interrupt(void) /* Sensible defaults */ WRITE_SYSREG64(0, CNTVOFF_EL2); /* No VM-specific offset */ /* Do not let the VMs program the physical timer, only read the physical counter */ - WRITE_SYSREG32(CNTHCTL_PA, CNTHCTL_EL2); + WRITE_SYSREG32(CNTHCTL_EL2_EL1PCTEN, CNTHCTL_EL2); WRITE_SYSREG32(0, CNTP_CTL_EL0); /* Physical timer disabled */ WRITE_SYSREG32(0, CNTHP_CTL_EL2); /* Hypervisor's timer disabled */ isb(); diff --git a/xen/include/asm-arm/processor.h b/xen/include/asm-arm/processor.h index b7e88a6f7f..5ccf61fbf2 100644 --- a/xen/include/asm-arm/processor.h +++ b/xen/include/asm-arm/processor.h @@ -555,8 +555,8 @@ union hsr { #define FSC_LL_MASK (_AC(0x03,U)<<0) /* Time counter hypervisor control register */ -#define CNTHCTL_PA (1u<<0) /* Kernel/user access to physical counter */ -#define CNTHCTL_TA (1u<<1) /* Kernel/user access to CNTP timer */ +#define CNTHCTL_EL2_EL1PCTEN (1u<<0) /* Kernel/user access to physical counter */ +#define CNTHCTL_EL2_EL1PCEN (1u<<1) /* Kernel/user access to CNTP timer regs */ /* Time counter kernel control register */ #define CNTKCTL_EL1_EL0PCTEN (1u<<0) /* Expose phys counters to EL0 */